import request from '@/utils/request'

const notebookApi = {
    notebooklist: '/apl_notepad/list', // 记事本的分页查询方法
    notebooksave: '/apl_notepad/save', //记事本保存更新方法
    removenotebook: '/apl_notepad/delete', //通过id删除 记事本 记录
    viewByApplyid: '/apl_notepad/viewByApplyid', //通过applyid 查询 记事本信息
}

/**
 * 记事本分页查询方法
 * @param {*} body 
 * @returns 
 */
export function notebooklist (body) {
    return request({
      url: notebookApi.notebooklist,
      method: 'post',
      data: body
    })
  }

export function notebooksave (body) {
  return request({
    url: notebookApi.notebooksave,
    method: 'post',
    data: body
    })
}

export function removenotebook (id) {
  return request({
    url: notebookApi.removenotebook,
    method: 'post',
    params: {
      id: id
    }
    })
}

export function viewByApplyid (applyid) {
  return request({
    url: notebookApi.viewByApplyid,
    method: 'get',
    params: {
      applyid: applyid
    }
    })
}
